import axios from '@/libs/api.request'

// 年度普调
export class YearAdjustmentRangeApi {
  // 根据条件获取年度普调明细
  static getList (params) {
    return axios.request({
      url: '/YearAdjustmentRange/GetList',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 根据年度普调批量调基
  static batchAdjustment (params) {
    return axios.request({
      url: '/YearAdjustmentRange/BatchAdjustment',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 删除年度普调明细
  static delete (params) {
    return axios.request({
      url: '/YearAdjustmentRange/Delete',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 导入
  static import (params) {
    return axios.request({
      url: '/YearAdjustmentRange/Import',
      method: 'post',
      enctype: 'multipart/form-data',
      data: params
    })
  }

  // 导出模板
  static exportTemplate (params) {
    return axios.request({
      url: '/YearAdjustmentRange/ExportTemplate',
      method: 'get',
      enctype: 'multipart/form-data',
      params: params,
      responseType: 'blob'
    })
  }

  // 导出错误数据附件
  static exportErrorFile (params) {
    return axios.request({
      url: '/YearAdjustmentRange/ExportErrorFile',
      method: 'get',
      enctype: 'multipart/form-data',
      params: params,
      responseType: 'blob'
    })
  }
}
